{% extends "base.html" %}
            {% block control %}<li class="treeview active">{% endblock %}
          {% block node %}
                <li class="active"><a href="/node/"><i class="fa fa-genderless"></i>节点管理</a></li>
             {% endblock %}

      <!-- Content Wrapper. Contains page content -->
             {% block content %}

          <ol class="breadcrumb">
            <li><a href="/"><i class="fa fa-television"></i> 管理中心</a></li>
            <li><a href="/node">节点列表</a></li>
            <li class="active">{{ node.node_name }}</li>
          </ol>

        <!-- Main content -->
         <section class="content">
             <form class="form-horizontal" id="myModal" tabindex="-1" role="dialog"
                   aria-labelledby="myModalLabel" aria-hidden="true"  method="post">
                    {% csrf_token %}
                   <div class="modal-dialog">
                      <div class="modal-content">
                         <div class="modal-header">
                            <h4 class="modal-title" id="myModalLabel">
                               修改节点
                            </h4>
                         </div>
                         <div class=" box-body">
                             <div class="form-group">
                                 <div class="col-sm-5 control-label">
                             {{ form.node_name.label_tag }}</div>
                                 <div class="col-sm-7">
                                     {{ form.node_name }}
                                  </div>
                             </div>
                             <div class="form-group">
                                 <div class="col-sm-5 control-label">
                             {{ form.NodeIP.label_tag }}</div>
                                 <div class="col-sm-7">
                                     {{ form.NodeIP }}
                                  </div>
                             </div>
                             <div class="form-group">
                                 <div class="col-sm-5 control-label">
                             {{ form.token.label_tag }}</div>
                                 <div class="col-sm-7">
                                     {{ form.token }}
                                  </div>
                             </div>
                             <div class="form-group">
                                 <div class="col-sm-5 control-label">
                             节点组</div>
                                 <div class="col-sm-7">
                                     {{ form.nodegroup }}
                                  </div>
                             </div>
                             <div class="form-group">
                                 <div class="col-sm-5 control-label">
                             线路标签</div>
                                 <div class="col-sm-7">
                                     {{ form.route }}
                                  </div>
                             </div>
                         </div>
                         <div class="modal-footer">
                            <a href="/node/"><button type="button" class="btn btn-default">关闭</button></a>
                            <button type="submit" class="btn btn-primary">
                               添加
                            </button>
                         </div>
                      </div><!-- /.modal-content -->
                </div><!-- /.modal -->
                </form>

        </section><!-- /.content -->
    {% endblock %}

  {% block js %}
    {% load staticfiles %}
        <!-- DataTables -->
    <script src="{% static "plugins/datatables/jquery.dataTables.min.js" %}"></script>
    <script src="{% static "plugins/datatables/dataTables.bootstrap.min.js" %}"></script>

    <!-- Optionally, you can add Slimscroll and FastClick plugins.
         Both of these plugins are recommended to enhance the
         user experience. Slimscroll is required when using the
         fixed layout. -->
      <script>

      $(function () {
        $("#example1").DataTable();
      });
    </script>
  {% endblock %}
